package test;

class MyThread extends Thread {
    @Override
    public void run() {
        while (true) {
            System.out.println(" hello Thread");
        }
    }
}

public class Demo1 {
    public static void main(String[] args) {
        MyThread t1 = new MyThread();
        t1.start();
        while(true) {
            System.out.println(" hello main");
        }
    }
}
